package com.miaoke;

import java.lang.reflect.Proxy;

public class RpcProxyFactory {
    public static <T> T getInstanceProxyByInterfaceClass(Class<T> clazz){
        return (T)Proxy.newProxyInstance(RpcProxyFactory.class.getClassLoader(),new Class[]{clazz},new RpcInvocationHandler(clazz));
    }
}
